package game.scene.sceneobject;

import common.Coordinate;
import common.Rectangle;

import engine.video.blit.Blitter;
import engine.video.blit.PixelBuffer_I;

/**
 * SceneObject_A Abstract class definition for a SceneObject
 **/
public abstract class SceneObject_A implements Comparable<SceneObject_A> {
	{
		VisRect = new Rectangle();
	}
	public Rectangle VisRect;
	public int Priority;
	
	public abstract boolean isOverlapping(Rectangle queryRect);
	public abstract void render(Coordinate camera, Blitter buffer);
	public abstract void setLocation(Coordinate location);
	public abstract void setBoundry(Rectangle boundry);

	/**
	 * Sorting logic for rendering order. Scene objects are sorted by Priority.
	 * Do not override this method.
	 **/
	@Override
	public int compareTo(SceneObject_A other) {
		return Priority - other.Priority;
	}
	
	
}
